package edu.nf.service.impl;



import edu.nf.beans.annotations.Component;
import edu.nf.beans.annotations.Inject;
import edu.nf.dao.AddDepartmDao;
import edu.nf.entity.Departm;
import edu.nf.exception.UpdateException;
import edu.nf.service.AddDepartmService;

@Component("addDepartmService")
public class AddDepartmServiceImpl implements AddDepartmService {

    @Inject(beanName = "addDepartm")
    private AddDepartmDao dao;

    @Override
    public void addDepartm(Departm departm) {
        try {
            dao.addClassInfo(departm);
        } catch (Exception e) {
            throw new UpdateException("add Departm fail...");
        }
    }
}
